import config from "@/config"
import http from "@/utils/request"

export default {
	list: {
		url: `${config.API_URL}/merchant/admin/index`,
		name: "获取管理员列表",
		get: async function(data={}){
			return await http.get(this.url, data);
		}
	},
	add: {
		url: `${config.API_URL}/merchant/admin/add`,
		name: "添加管理员",
		post: async function(data={}){
			return await http.post(this.url, data);
		}
	},
	getAddInfo: {
		url: `${config.API_URL}/merchant/admin/add`,
		name: "获取新增信息",
		get: async function(data={}){
			return await http.get(this.url, data);
		}
	},
	edit: {
		url: `${config.API_URL}/merchant/admin/edit`,
		name: "编辑商品参数",
		post: async function(data={}){
			return await http.post(this.url, data);
		}
	},
	getEditInfo: {
		url: `${config.API_URL}/merchant/admin/edit`,
		name: "获取编辑商品信息",
		get: async function(data={}){
			return await http.get(this.url, data);
		}
	},
	del: {
		url: `${config.API_URL}/merchant/admin/del`,
		name: "删除商品",
		get: async function(data={}){
			return await http.get(this.url, data);
		}
	}
}
